package com.xnew.bean.common;


import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.xnew.entity.memberinfo.MemPayTask;
import org.springframework.data.annotation.Transient;

import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

@TableName(" el_sys_org_user_info")
public class SysOrgUserInfo implements Serializable {

	@TableId
	private String orgId; //机构用户编号

	private String orgAttrCode; // 机构属性编号

	private String beltoRegiCode; // 地区编号

	private String indvUserNo; //用户编号

	private String orgTypeCode; //机构类别编号

	private String orgName; //机构名称

	private String orgCode; //机构代码

	private String aoiOrgNo; //组织机构代码

	private String createPsnNo; //添加人

	private String createTime; //添加时间

	private String updatePsnNo; //修改人

	private String updateTime; //修改时间

	private String orgStatusCode; //机构状态

	private String loginName; //登录名',

	private String orgDutyCode; //机构职务编码：03理事单位、04监事单位、05常务理事单位、06非会员单位

	private String orgCertifNo; //会员证书号码

	private String closeDate; //关闭时间

	@TableField(exist = false)
	private Integer rowNum;

	@TableField(exist = false)
	private String linkmanName;

	@TableField(exist = false)
	private String arIds;//角色编号

	@TableField(exist = false)
	private String openId;

//财务系统编号， 主要是统计那边用 需要对应上
	private String finRepCode;

	@TableField(exist = false)
	private T10MemOrgLinkmanInfo memOrgLinkmanInfo;
	@TableField(exist = false)
	private List<Map<String, String>> auUserRoleList;//角色关系表

	public Integer getRowNum() {
		return rowNum;
	}

	public void setRowNum(Integer rowNum) {
		this.rowNum = rowNum;
	}

	public T10MemOrgLinkmanInfo getMemOrgLinkmanInfo() {
		return memOrgLinkmanInfo;
	}

	public void setMemOrgLinkmanInfo(T10MemOrgLinkmanInfo memOrgLinkmanInfo) {
		this.memOrgLinkmanInfo = memOrgLinkmanInfo;
	}

	public List<Map<String, String>> getAuUserRoleList() {
		return auUserRoleList;
	}

	public void setAuUserRoleList(List<Map<String, String>> auUserRoleList) {
		this.auUserRoleList = auUserRoleList;
	}

	@TableField(exist = false)
	private MemPayTask memPayTask;

	public MemPayTask getMemPayTask() {
		return memPayTask;
	}

	public void setMemPayTask(MemPayTask memPayTask) {
		this.memPayTask = memPayTask;
	}

	@Transient
	@JsonInclude(JsonInclude.Include.NON_NULL)
	@TableField(exist = false)
	private Map<String, Object> dictNameResult = new HashMap<String, Object>();

	public Map<String, Object> getDictNameResult() {
		return dictNameResult;
	}

	public void setDictNameResult(Map<String, Object> dictNameResult) {
		this.dictNameResult = dictNameResult;
	}

	//数据字典
	@Transient
	@JsonInclude(JsonInclude.Include.NON_NULL)
	public String[] buildIncludeField(){
		return new String[]{"orgAttrCode","orgTypeCode","orgDutyCode","orgStatusCode","beltoRegiCode"};
	}

	/*数据字典*/
	@Transient
	@JsonInclude(JsonInclude.Include.NON_NULL)
	public String[] buildIncludeType(){
		return new String[]{"DG0470","DG0443","DG0125","DG0031","DG0060"};
	}

	private static final long serialVersionUID = 57325375375L;


	public String getFinRepCode() {
		return finRepCode;
	}

	public void setFinRepCode(String finRepCode) {
		this.finRepCode = finRepCode;
	}

	public String getArIds() {
		return arIds;
	}

	public void setArIds(String arIds) {
		this.arIds = arIds;
	}

	public static long getSerialVersionUID() {
		return serialVersionUID;
	}

	public String getOrgId() {
		return orgId;
	}

	public void setOrgId(String orgId) {
		this.orgId = orgId == null ? null : orgId.trim();
	}

	public String getOrgAttrCode() {
		return orgAttrCode;
	}

	public void setOrgAttrCode(String orgAttrCode) {
		this.orgAttrCode = orgAttrCode == null ? null : orgAttrCode.trim();
	}

	public String getBeltoRegiCode() {
		return beltoRegiCode;
	}

	public void setBeltoRegiCode(String beltoRegiCode) {
		this.beltoRegiCode = beltoRegiCode == null ? null : beltoRegiCode.trim();
	}

	public String getIndvUserNo() {
		return indvUserNo;
	}

	public void setIndvUserNo(String indvUserNo) {
		this.indvUserNo = indvUserNo == null ? null : indvUserNo.trim();
	}

	public String getOrgTypeCode() {
		return orgTypeCode;
	}

	public void setOrgTypeCode(String orgTypeCode) {
		this.orgTypeCode = orgTypeCode == null ? null : orgTypeCode.trim();
	}

	public String getOrgName() {
		return orgName;
	}

	public void setOrgName(String orgName) {
		this.orgName = orgName == null ? null : orgName.trim();
	}

	public String getOrgCode() {
		return orgCode;
	}

	public void setOrgCode(String orgCode) {
		this.orgCode = orgCode == null ? null : orgCode.trim();
	}

	public String getAoiOrgNo() {
		return aoiOrgNo;
	}

	public void setAoiOrgNo(String aoiOrgNo) {
		this.aoiOrgNo = aoiOrgNo == null ? null : aoiOrgNo.trim();
	}

	public String getCreatePsnNo() {
		return createPsnNo;
	}

	public void setCreatePsnNo(String createPsnNo) {
		this.createPsnNo = createPsnNo == null ? null : createPsnNo.trim();
	}

	public String getCreateTime() {
		return createTime;
	}

	public void setCreateTime(String createTime) {
		this.createTime = createTime == null ? null : createTime.trim();
	}

	public String getLinkmanName() {
		return linkmanName;
	}

	public void setLinkmanName(String linkmanName) {
		this.linkmanName = linkmanName == null ? null : linkmanName.trim();
	}

	public String getOpenId() {
		return openId;
	}

	public void setOpenId(String openId) {
		this.openId = openId == null ? null : openId.trim();
	}

	public String getUpdatePsnNo() {
		return updatePsnNo;
	}

	public void setUpdatePsnNo(String updatePsnNo) {
		this.updatePsnNo = updatePsnNo == null ? null : updatePsnNo.trim();
	}

	public String getUpdateTime() {
		return updateTime;
	}

	public void setUpdateTime(String updateTime) {
		this.updateTime = updateTime == null ? null : updateTime.trim();
	}

	public String getOrgStatusCode() {
		return orgStatusCode;
	}

	public void setOrgStatusCode(String orgStatusCode) {
		this.orgStatusCode = orgStatusCode == null ? null : orgStatusCode.trim();
	}

	public String getLoginName() {
		return loginName;
	}

	public void setLoginName(String loginName) {
		this.loginName = loginName == null ? null : loginName.trim();
	}

	public String getOrgDutyCode() {
		return orgDutyCode;
	}

	public void setOrgDutyCode(String orgDutyCode) {
		this.orgDutyCode = orgDutyCode == null ? null : orgDutyCode.trim();
	}

	public String getOrgCertifNo() {
		return orgCertifNo;
	}

	public void setOrgCertifNo(String orgCertifNo) {
		this.orgCertifNo = orgCertifNo == null ? null : orgCertifNo.trim();
	}

	public String getCloseDate() {
		return closeDate;
	}

	public void setCloseDate(String closeDate) {
		this.closeDate = closeDate == null ? null : closeDate.trim();
	}


	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder();
		sb.append(getClass().getSimpleName());
		sb.append(" [");
		sb.append("Hash = ").append(hashCode());
		sb.append(", orgId=").append(orgId);
		sb.append(", orgAttrCode=").append(orgAttrCode);
		sb.append(", beltoRegiCode=").append(beltoRegiCode);
		sb.append(", indvUserNo=").append(indvUserNo);
		sb.append(", orgTypeCode=").append(orgTypeCode);
		sb.append(", orgName=").append(orgName);
		sb.append(", orgCode=").append(orgCode);
		sb.append(", aoiOrgNo=").append(aoiOrgNo);
		sb.append(", createPsnNo=").append(createPsnNo);
		sb.append(", createTime=").append(createTime);
		sb.append(", updatePsnNo=").append(updatePsnNo);
		sb.append(", updateTime=").append(updateTime);
		sb.append(", orgStatusCode=").append(orgStatusCode);
		sb.append(", loginName=").append(loginName);
		sb.append(", orgDutyCode=").append(orgDutyCode);
		sb.append(", orgCertifNo=").append(orgCertifNo);
		sb.append(", closeDate=").append(closeDate);
		sb.append(", serialVersionUID=").append(serialVersionUID);
		sb.append("]");
		return sb.toString();
	}


	@Override
	public boolean equals(Object that) {
		if (this == that) {
			return true;
		}
		if (that == null) {
			return false;
		}
		if (getClass() != that.getClass()) {
			return false;
		}
		SysOrgUserInfo other = (SysOrgUserInfo) that;
		return (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
				&& (this.getOrgAttrCode() == null ? other.getOrgAttrCode() == null : this.getOrgAttrCode().equals(other.getOrgAttrCode()))
				&& (this.getBeltoRegiCode() == null ? other.getBeltoRegiCode() == null : this.getBeltoRegiCode().equals(other.getBeltoRegiCode()))
				&& (this.getIndvUserNo() == null ? other.getIndvUserNo() == null : this.getIndvUserNo().equals(other.getIndvUserNo()))
				&& (this.getOrgTypeCode() == null ? other.getOrgTypeCode() == null : this.getOrgTypeCode().equals(other.getOrgTypeCode()))
				&& (this.getOrgName() == null ? other.getOrgName() == null : this.getOrgName().equals(other.getOrgName()))
				&& (this.getOrgCode() == null ? other.getOrgCode() == null : this.getOrgCode().equals(other.getOrgCode()))
				&& (this.getAoiOrgNo() == null ? other.getAoiOrgNo() == null : this.getAoiOrgNo().equals(other.getAoiOrgNo()))
				&& (this.getCreatePsnNo() == null ? other.getCreatePsnNo() == null : this.getCreatePsnNo().equals(other.getCreatePsnNo()))
				&& (this.getCreateTime() == null ? other.getCreateTime() == null : this.getCreateTime().equals(other.getCreateTime()))
				&& (this.getUpdatePsnNo() == null ? other.getUpdatePsnNo() == null : this.getUpdatePsnNo().equals(other.getUpdatePsnNo()))
				&& (this.getUpdateTime() == null ? other.getUpdateTime() == null : this.getUpdateTime().equals(other.getUpdateTime()))
				&& (this.getOrgStatusCode() == null ? other.getOrgStatusCode() == null : this.getOrgStatusCode().equals(other.getOrgStatusCode()))
				&& (this.getLoginName() == null ? other.getLoginName() == null : this.getLoginName().equals(other.getLoginName()))
				&& (this.getOrgDutyCode() == null ? other.getOrgDutyCode() == null : this.getOrgDutyCode().equals(other.getOrgDutyCode()))
				&& (this.getOrgCertifNo() == null ? other.getOrgCertifNo() == null : this.getOrgCertifNo().equals(other.getOrgCertifNo()))
				&& (this.getCloseDate() == null ? other.getCloseDate() == null : this.getCloseDate().equals(other.getCloseDate()));
	}


	@Override
	public int hashCode() {
		final int prime = 31;
		int result = 1;
		result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
		result = prime * result + ((getOrgAttrCode() == null) ? 0 : getOrgAttrCode().hashCode());
		result = prime * result + ((getBeltoRegiCode() == null) ? 0 : getBeltoRegiCode().hashCode());
		result = prime * result + ((getIndvUserNo() == null) ? 0 : getIndvUserNo().hashCode());
		result = prime * result + ((getOrgTypeCode() == null) ? 0 : getOrgTypeCode().hashCode());
		result = prime * result + ((getOrgName() == null) ? 0 : getOrgName().hashCode());
		result = prime * result + ((getOrgCode() == null) ? 0 : getOrgCode().hashCode());
		result = prime * result + ((getAoiOrgNo() == null) ? 0 : getAoiOrgNo().hashCode());
		result = prime * result + ((getCreatePsnNo() == null) ? 0 : getCreatePsnNo().hashCode());
		result = prime * result + ((getCreateTime() == null) ? 0 : getCreateTime().hashCode());
		result = prime * result + ((getUpdatePsnNo() == null) ? 0 : getUpdatePsnNo().hashCode());
		result = prime * result + ((getUpdateTime() == null) ? 0 : getUpdateTime().hashCode());
		result = prime * result + ((getOrgStatusCode() == null) ? 0 : getOrgStatusCode().hashCode());
		result = prime * result + ((getLoginName() == null) ? 0 : getLoginName().hashCode());
		result = prime * result + ((getOrgDutyCode() == null) ? 0 : getOrgDutyCode().hashCode());
		result = prime * result + ((getOrgCertifNo() == null) ? 0 : getOrgCertifNo().hashCode());
		result = prime * result + ((getCloseDate() == null) ? 0 : getCloseDate().hashCode());
		return result;
	}
}
